<%@ page language="java" import="java.io.*,java.util.*,java.sql.*" contentType="text/html; charset=utf-8"%>
<!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN" "http://www.w3.org/TR/html4/loose.dtd">
<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=utf-8">
<title>Insert title here</title>
</head>
<body>
     <%
     Class.forName("com.mysql.jdbc.Driver");
     Connection con = DriverManager.getConnection("jdbc:mysql://localhost:3306/bank","root","123456");
     String sql = "select * from bank";
     PreparedStatement pstm = con.prepareStatement(sql);
     ResultSet rs = pstm.executeQuery();
     out.println("<tr><th width=100>account</th>" +
             "<th width=100>money</th></br>");
     while(rs.next()){
    	 out.println("<tr><th width=100>"+rs.getString("acno")+"</th>" +
                 "<th width=100>"+rs.getString("money")+"</th></br>");
     }%>
</body>
</html>